#
# Copyright (C) 2011 The Android Open-Source Project
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
#      http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
#

# This file includes all definitions that apply to ALL crespo2 devices, and
# are also specific to crespo2 devices
#
# Everything in this directory will become public

ifeq ($(TARGET_PREBUILT_KERNEL),)
LOCAL_KERNEL := device/samsung/crespo2/kernel
else
LOCAL_KERNEL := $(TARGET_PREBUILT_KERNEL)
endif

DEVICE_PACKAGE_OVERLAYS := device/samsung/crespo2/overlay

# These are the hardware-specific configuration files
PRODUCT_COPY_FILES := \
	device/samsung/crespo/vold.fstab:system/etc/vold.fstab \
	device/samsung/crespo/egl.cfg:system/lib/egl/egl.cfg



# This device is xhdpi.  However the platform doesn't
# currently contain all of the bitmaps at xhdpi density so
# we do this little trick to fall back to the hdpi version
# if the xhdpi doesn't exist.
PRODUCT_AAPT_CONFIG := normal hdpi 
PRODUCT_AAPT_PREF_CONFIG := hdpi

PRODUCT_PACKAGES := \
	charger \
	charger_res_images

PRODUCT_PACKAGES += \
	libinvensense_mpl

PRODUCT_PACKAGES += \
	audio.a2dp.default \
	libaudioutils

PRODUCT_PACKAGES += \
	crespo2_hdcp_keys

# Init files
PRODUCT_COPY_FILES += \
	device/samsung/crespo/init.herring.rc:root/init.herring.rc \
	device/samsung/crespo/ueventd.herring.rc:root/ueventd.herring.rc

# Prebuilt kl keymaps
PRODUCT_COPY_FILES += \
	device/samsung/crespo/s3c-keypad.kl:system/usr/keylayout/s3c-keypad.kl \
	device/samsung/crespo/cypress-touchkey.kl:system/usr/keylayout/cypress-touchkey.kl \
	device/samsung/crespo/sec_jack.kl:system/usr/keylayout/sec_jack.kl \
	device/samsung/crespo/herring-keypad.kl:system/usr/keylayout/herring-keypad.kl



PRODUCT_COPY_FILES := \
	$(LOCAL_KERNEL):kernel \
	device/samsung/crespo2/ueventd.herring.rc:root/ueventd.herring.rc \
	device/samsung/crespo2/media_profiles.xml:system/etc/media_profiles.xml \
	device/samsung/crespo2/gps.conf:system/etc/gps.conf




# Input device calibration files
PRODUCT_COPY_FILES += \
	device/samsung/crespo2/mxt224_ts_input.idc:system/usr/idc/mxt224_ts_input.idc






PRODUCT_PROPERTY_OVERRIDES += \
	ro.opengles.version=131072

PRODUCT_PROPERTY_OVERRIDES += \
	ro.sf.lcd_density=240

PRODUCT_CHARACTERISTICS := nosdcard

PRODUCT_TAGS += dalvik.gc.type-precise


# Filesystem management tools
PRODUCT_PACKAGES += \
	make_ext4fs \
	setup_fs

# for bugmailer
ifneq ($(TARGET_BUILD_VARIANT),user)
	PRODUCT_PACKAGES += send_bug
	PRODUCT_COPY_FILES += \
		system/extras/bugmailer/bugmailer.sh:system/bin/bugmailer.sh \
		system/extras/bugmailer/send_bug:system/bin/send_bug
endif

$(call inherit-product, frameworks/base/build/phone-xhdpi-1024-dalvik-heap.mk)

$(call inherit-product-if-exists, vendor/samsung/crespo/device-vendor.mk)

